package com.pkk.cloud.support.admin.oauth2.api.admin;

import com.pkk.cloud.support.admin.oauth2.api.common.req.PenguinModifyPasswordReq;
import com.pkk.cloud.support.admin.oauth2.api.common.req.PenguinSysUserIdReq;
import com.pkk.cloud.support.admin.oauth2.api.common.req.PenguinSysUserNameReq;
import com.pkk.cloud.support.admin.oauth2.api.common.resp.PenguinSysUserInfo;
import com.pkk.cloud.support.admin.oauth2.api.common.resp.PenguinSysUserAuthorizeResp;
import com.pkk.components.rpc.request.CommonRequest;
import com.pkk.components.rpc.response.CommonResponse;
import com.pkk.components.rpc.response.util.ResponseUtil;
import org.springframework.context.annotation.Configuration;

/**
 * @description: admin接口的熔断器
 * @author: peikunkun
 * @create: 2020-03-18 13:39
 **/
@Configuration
public class AdminApiHystrix implements AdminApi {

  public AdminApiHystrix() {
  }

  /**
   * @Description: 获取用户信息
   * @Author: peikunkun
   * @Date: 2020/03/18 10:16
   */
  @Override
  public CommonResponse<PenguinSysUserInfo> loadUserByUsername(CommonRequest<PenguinSysUserNameReq> request) {
    return ResponseUtil.error();
  }

  /**
   * @Description: 获取授权用户
   * @Author: peikunkun
   * @Date: 2020/03/18 10:18
   */
  @Override
  public CommonResponse<PenguinSysUserAuthorizeResp> getAuthorize(CommonRequest<PenguinSysUserIdReq> request) {
    return ResponseUtil.error();
  }

  /**
   * @Description: 修改密码
   * @Author: peikunkun
   * @Date: 2020/03/18 10:18
   */
  @Override
  public CommonResponse<?> modifyUserPwd(CommonRequest<PenguinModifyPasswordReq> request) {
    return ResponseUtil.error();
  }
}
